package cn.ililes.tools.nosql.spring.tests;

import org.springframework.test.AbstractDependencyInjectionSpringContextTests;

public abstract class BaseTest extends AbstractDependencyInjectionSpringContextTests {

	//@Override
	protected String[] getConfigLocations() {
		return new String[] { "classpath:application-transaction.xml"

		};

	};

	public <E> E getService(String name) {
		try {
			E object = (E) getApplicationContext().getBean(name);
			return object;
		} catch (Exception e) {
			e.printStackTrace();
			throw new RuntimeException(e);
		}
	}

	public <E> E getotherService(String name) {
		try {
			E object = (E) getApplicationContext().getBean(name);
			return object;
		} catch (Exception e) {
			e.printStackTrace();
			throw new RuntimeException(e);
		}
	}

}
